#!/bin/bash

ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/../.." && pwd)"
FREQUENCY=30

BINARY="bazel-bin/cc/appcoin2/support/feed/ticker_provider"
CONFIG_COMMON="cc/appcoin2/support/feed/ticker_provider_tool/mid_price_provider_config.json"
COMMAND="${BINARY} --driver=${CONFIG_COMMON} --write_h5=True"

export GLOG_logtostderr=1
source /remote/iosg/home-2/bot-coin/miniconda3/etc/profile.d/conda.sh
conda activate /remote/iosg/home-2/bot-coin/miniconda3/envs/coin2_motion_env_migration

while :
do
  ${COMMAND}
  sleep ${FREQUENCY}
done

conda deactivate